Integrand size = 20, antiderivative size = 185 \[ \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx=\frac {12 f \sqrt {c+d x} \cos \left (a+b \sqrt {c+d x}\right )}{b^3 d^2}-\frac {2 (d e-c f) \sqrt {c+d x} \cos \left (a+b \sqrt {c+d x}\right )}{b d^2}-\frac {2 f (c+d x)^{3/2} \cos \left (a+b \sqrt {c+d x}\right )}{b d^2}-\frac {12 f \sin \left (a+b \sqrt {c+d x}\right )}{b^4 d^2}+\frac {2 (d e-c f) \sin \left (a+b \sqrt {c+d x}\right )}{b^2 d^2}+\frac {6 f (c+d x) \sin \left (a+b \sqrt {c+d x}\right )}{b^2 d^2} \]
-2*f*(d*x+c)^(3/2)*cos(a+b*(d*x+c)^(1/2))/b/d^2-12*f*sin(a+b*(d*x+c)^(1/2) )/b^4/d^2+2*(-c*f+d*e)*sin(a+b*(d*x+c)^(1/2))/b^2/d^2+6*f*(d*x+c)*sin(a+b* (d*x+c)^(1/2))/b^2/d^2+12*f*cos(a+b*(d*x+c)^(1/2))*(d*x+c)^(1/2)/b^3/d^2-2 *(-c*f+d*e)*cos(a+b*(d*x+c)^(1/2))*(d*x+c)^(1/2)/b/d^2
Time = 0.41 (sec) , antiderivative size = 85, normalized size of antiderivative = 0.46 \[ \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx=\frac {-2 b \sqrt {c+d x} \left (-6 f+b^2 d (e+f x)\right ) \cos \left (a+b \sqrt {c+d x}\right )+2 \left (-6 f+b^2 (2 c f+d (e+3 f x))\right ) \sin \left (a+b \sqrt {c+d x}\right )}{b^4 d^2} \]
(-2*b*Sqrt[c + d*x]*(-6*f + b^2*d*(e + f*x))*Cos[a + b*Sqrt[c + d*x]] + 2* (-6*f + b^2*(2*c*f + d*(e + 3*f*x)))*Sin[a + b*Sqrt[c + d*x]])/(b^4*d^2)
Time = 0.33 (sec) , antiderivative size = 189, normalized size of antiderivative = 1.02, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {3912, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx\) |
\(\Big \downarrow \) 3912 |
\(\displaystyle \frac {2 \int \left (\frac {f \sin \left (a+b \sqrt {c+d x}\right ) (c+d x)^{3/2}}{d}+\frac {(d e-c f) \sin \left (a+b \sqrt {c+d x}\right ) \sqrt {c+d x}}{d}\right )d\sqrt {c+d x}}{d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {2 \left (-\frac {6 f \sin \left (a+b \sqrt {c+d x}\right )}{b^4 d}+\frac {6 f \sqrt {c+d x} \cos \left (a+b \sqrt {c+d x}\right )}{b^3 d}+\frac {(d e-c f) \sin \left (a+b \sqrt {c+d x}\right )}{b^2 d}+\frac {3 f (c+d x) \sin \left (a+b \sqrt {c+d x}\right )}{b^2 d}-\frac {\sqrt {c+d x} (d e-c f) \cos \left (a+b \sqrt {c+d x}\right )}{b d}-\frac {f (c+d x)^{3/2} \cos \left (a+b \sqrt {c+d x}\right )}{b d}\right )}{d}\) |
(2*((6*f*Sqrt[c + d*x]*Cos[a + b*Sqrt[c + d*x]])/(b^3*d) - ((d*e - c*f)*Sq rt[c + d*x]*Cos[a + b*Sqrt[c + d*x]])/(b*d) - (f*(c + d*x)^(3/2)*Cos[a + b *Sqrt[c + d*x]])/(b*d) - (6*f*Sin[a + b*Sqrt[c + d*x]])/(b^4*d) + ((d*e - c*f)*Sin[a + b*Sqrt[c + d*x]])/(b^2*d) + (3*f*(c + d*x)*Sin[a + b*Sqrt[c + d*x]])/(b^2*d)))/d
3.2.88.3.1 Defintions of rubi rules used
Int[((g_.) + (h_.)*(x_))^(m_.)*((a_.) + (b_.)*Sin[(c_.) + (d_.)*((e_.) + (f _.)*(x_))^(n_)])^(p_.), x_Symbol] :> Simp[1/(n*f) Subst[Int[ExpandIntegra nd[(a + b*Sin[c + d*x])^p, x^(1/n - 1)*(g - e*(h/f) + h*(x^(1/n)/f))^m, x], x], x, (e + f*x)^n], x] /; FreeQ[{a, b, c, d, e, f, g, h, m}, x] && IGtQ[p , 0] && IntegerQ[1/n]
Leaf count of result is larger than twice the leaf count of optimal. \(346\) vs. \(2(167)=334\).
Time = 0.37 (sec) , antiderivative size = 347, normalized size of antiderivative = 1.88
method | result | size |
parts | \(-\frac {2 \sqrt {d x +c}\, \cos \left (a +b \sqrt {d x +c}\right ) f x}{d b}-\frac {2 \sqrt {d x +c}\, \cos \left (a +b \sqrt {d x +c}\right ) e}{d b}+\frac {2 \sin \left (a +b \sqrt {d x +c}\right ) f x}{d \,b^{2}}+\frac {2 \sin \left (a +b \sqrt {d x +c}\right ) e}{d \,b^{2}}-\frac {2 f \left (\frac {2 a \left (\cos \left (a +b \sqrt {d x +c}\right )+\left (a +b \sqrt {d x +c}\right ) \sin \left (a +b \sqrt {d x +c}\right )-a \sin \left (a +b \sqrt {d x +c}\right )\right )}{d \,b^{2}}-\frac {2 \left (\left (a +b \sqrt {d x +c}\right )^{2} \sin \left (a +b \sqrt {d x +c}\right )-2 \sin \left (a +b \sqrt {d x +c}\right )+2 \left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )-a \left (\cos \left (a +b \sqrt {d x +c}\right )+\left (a +b \sqrt {d x +c}\right ) \sin \left (a +b \sqrt {d x +c}\right )\right )\right )}{d \,b^{2}}+\frac {2 \sin \left (a +b \sqrt {d x +c}\right )-2 \left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )+2 a \cos \left (a +b \sqrt {d x +c}\right )}{b^{2} d}\right )}{d \,b^{2}}\) | \(347\) |
derivativedivides | \(\frac {-2 c f a \cos \left (a +b \sqrt {d x +c}\right )+2 d e a \cos \left (a +b \sqrt {d x +c}\right )-2 c f \left (\sin \left (a +b \sqrt {d x +c}\right )-\left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )+2 d e \left (\sin \left (a +b \sqrt {d x +c}\right )-\left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )+\frac {2 a^{3} f \cos \left (a +b \sqrt {d x +c}\right )}{b^{2}}+\frac {6 a^{2} f \left (\sin \left (a +b \sqrt {d x +c}\right )-\left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )}{b^{2}}-\frac {6 a f \left (-\left (a +b \sqrt {d x +c}\right )^{2} \cos \left (a +b \sqrt {d x +c}\right )+2 \cos \left (a +b \sqrt {d x +c}\right )+2 \left (a +b \sqrt {d x +c}\right ) \sin \left (a +b \sqrt {d x +c}\right )\right )}{b^{2}}+\frac {2 f \left (-\left (a +b \sqrt {d x +c}\right )^{3} \cos \left (a +b \sqrt {d x +c}\right )+3 \left (a +b \sqrt {d x +c}\right )^{2} \sin \left (a +b \sqrt {d x +c}\right )-6 \sin \left (a +b \sqrt {d x +c}\right )+6 \left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )}{b^{2}}}{d^{2} b^{2}}\) | \(366\) |
default | \(\frac {-2 c f a \cos \left (a +b \sqrt {d x +c}\right )+2 d e a \cos \left (a +b \sqrt {d x +c}\right )-2 c f \left (\sin \left (a +b \sqrt {d x +c}\right )-\left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )+2 d e \left (\sin \left (a +b \sqrt {d x +c}\right )-\left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )+\frac {2 a^{3} f \cos \left (a +b \sqrt {d x +c}\right )}{b^{2}}+\frac {6 a^{2} f \left (\sin \left (a +b \sqrt {d x +c}\right )-\left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )}{b^{2}}-\frac {6 a f \left (-\left (a +b \sqrt {d x +c}\right )^{2} \cos \left (a +b \sqrt {d x +c}\right )+2 \cos \left (a +b \sqrt {d x +c}\right )+2 \left (a +b \sqrt {d x +c}\right ) \sin \left (a +b \sqrt {d x +c}\right )\right )}{b^{2}}+\frac {2 f \left (-\left (a +b \sqrt {d x +c}\right )^{3} \cos \left (a +b \sqrt {d x +c}\right )+3 \left (a +b \sqrt {d x +c}\right )^{2} \sin \left (a +b \sqrt {d x +c}\right )-6 \sin \left (a +b \sqrt {d x +c}\right )+6 \left (a +b \sqrt {d x +c}\right ) \cos \left (a +b \sqrt {d x +c}\right )\right )}{b^{2}}}{d^{2} b^{2}}\) | \(366\) |
-2/d/b*(d*x+c)^(1/2)*cos(a+b*(d*x+c)^(1/2))*f*x-2/d/b*(d*x+c)^(1/2)*cos(a+ b*(d*x+c)^(1/2))*e+2/d/b^2*sin(a+b*(d*x+c)^(1/2))*f*x+2/d/b^2*sin(a+b*(d*x +c)^(1/2))*e-2/d/b^2*f*(2*a/d/b^2*(cos(a+b*(d*x+c)^(1/2))+(a+b*(d*x+c)^(1/ 2))*sin(a+b*(d*x+c)^(1/2))-a*sin(a+b*(d*x+c)^(1/2)))-2/d/b^2*((a+b*(d*x+c) ^(1/2))^2*sin(a+b*(d*x+c)^(1/2))-2*sin(a+b*(d*x+c)^(1/2))+2*(a+b*(d*x+c)^( 1/2))*cos(a+b*(d*x+c)^(1/2))-a*(cos(a+b*(d*x+c)^(1/2))+(a+b*(d*x+c)^(1/2)) *sin(a+b*(d*x+c)^(1/2))))+2/d/b^2*(sin(a+b*(d*x+c)^(1/2))-(a+b*(d*x+c)^(1/ 2))*cos(a+b*(d*x+c)^(1/2))+a*cos(a+b*(d*x+c)^(1/2))))
Time = 0.27 (sec) , antiderivative size = 86, normalized size of antiderivative = 0.46 \[ \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx=-\frac {2 \, {\left ({\left (b^{3} d f x + b^{3} d e - 6 \, b f\right )} \sqrt {d x + c} \cos \left (\sqrt {d x + c} b + a\right ) - {\left (3 \, b^{2} d f x + b^{2} d e + 2 \, {\left (b^{2} c - 3\right )} f\right )} \sin \left (\sqrt {d x + c} b + a\right )\right )}}{b^{4} d^{2}} \]
-2*((b^3*d*f*x + b^3*d*e - 6*b*f)*sqrt(d*x + c)*cos(sqrt(d*x + c)*b + a) - (3*b^2*d*f*x + b^2*d*e + 2*(b^2*c - 3)*f)*sin(sqrt(d*x + c)*b + a))/(b^4* d^2)
Time = 0.25 (sec) , antiderivative size = 221, normalized size of antiderivative = 1.19 \[ \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx=\begin {cases} \left (e x + \frac {f x^{2}}{2}\right ) \sin {\left (a \right )} & \text {for}\: b = 0 \wedge \left (b = 0 \vee d = 0\right ) \\\left (e x + \frac {f x^{2}}{2}\right ) \sin {\left (a + b \sqrt {c} \right )} & \text {for}\: d = 0 \\- \frac {2 e \sqrt {c + d x} \cos {\left (a + b \sqrt {c + d x} \right )}}{b d} - \frac {2 f x \sqrt {c + d x} \cos {\left (a + b \sqrt {c + d x} \right )}}{b d} + \frac {4 c f \sin {\left (a + b \sqrt {c + d x} \right )}}{b^{2} d^{2}} + \frac {2 e \sin {\left (a + b \sqrt {c + d x} \right )}}{b^{2} d} + \frac {6 f x \sin {\left (a + b \sqrt {c + d x} \right )}}{b^{2} d} + \frac {12 f \sqrt {c + d x} \cos {\left (a + b \sqrt {c + d x} \right )}}{b^{3} d^{2}} - \frac {12 f \sin {\left (a + b \sqrt {c + d x} \right )}}{b^{4} d^{2}} & \text {otherwise} \end {cases} \]
Piecewise(((e*x + f*x**2/2)*sin(a), Eq(b, 0) & (Eq(b, 0) | Eq(d, 0))), ((e *x + f*x**2/2)*sin(a + b*sqrt(c)), Eq(d, 0)), (-2*e*sqrt(c + d*x)*cos(a + b*sqrt(c + d*x))/(b*d) - 2*f*x*sqrt(c + d*x)*cos(a + b*sqrt(c + d*x))/(b*d ) + 4*c*f*sin(a + b*sqrt(c + d*x))/(b**2*d**2) + 2*e*sin(a + b*sqrt(c + d* x))/(b**2*d) + 6*f*x*sin(a + b*sqrt(c + d*x))/(b**2*d) + 12*f*sqrt(c + d*x )*cos(a + b*sqrt(c + d*x))/(b**3*d**2) - 12*f*sin(a + b*sqrt(c + d*x))/(b* *4*d**2), True))
Leaf count of result is larger than twice the leaf count of optimal. 348 vs. \(2 (167) = 334\).
Time = 0.20 (sec) , antiderivative size = 348, normalized size of antiderivative = 1.88 \[ \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx=\frac {2 \, {\left (a e \cos \left (\sqrt {d x + c} b + a\right ) - \frac {a c f \cos \left (\sqrt {d x + c} b + a\right )}{d} - {\left ({\left (\sqrt {d x + c} b + a\right )} \cos \left (\sqrt {d x + c} b + a\right ) - \sin \left (\sqrt {d x + c} b + a\right )\right )} e + \frac {{\left ({\left (\sqrt {d x + c} b + a\right )} \cos \left (\sqrt {d x + c} b + a\right ) - \sin \left (\sqrt {d x + c} b + a\right )\right )} c f}{d} + \frac {a^{3} f \cos \left (\sqrt {d x + c} b + a\right )}{b^{2} d} - \frac {3 \, {\left ({\left (\sqrt {d x + c} b + a\right )} \cos \left (\sqrt {d x + c} b + a\right ) - \sin \left (\sqrt {d x + c} b + a\right )\right )} a^{2} f}{b^{2} d} + \frac {3 \, {\left ({\left ({\left (\sqrt {d x + c} b + a\right )}^{2} - 2\right )} \cos \left (\sqrt {d x + c} b + a\right ) - 2 \, {\left (\sqrt {d x + c} b + a\right )} \sin \left (\sqrt {d x + c} b + a\right )\right )} a f}{b^{2} d} - \frac {{\left ({\left ({\left (\sqrt {d x + c} b + a\right )}^{3} - 6 \, \sqrt {d x + c} b - 6 \, a\right )} \cos \left (\sqrt {d x + c} b + a\right ) - 3 \, {\left ({\left (\sqrt {d x + c} b + a\right )}^{2} - 2\right )} \sin \left (\sqrt {d x + c} b + a\right )\right )} f}{b^{2} d}\right )}}{b^{2} d} \]
2*(a*e*cos(sqrt(d*x + c)*b + a) - a*c*f*cos(sqrt(d*x + c)*b + a)/d - ((sqr t(d*x + c)*b + a)*cos(sqrt(d*x + c)*b + a) - sin(sqrt(d*x + c)*b + a))*e + ((sqrt(d*x + c)*b + a)*cos(sqrt(d*x + c)*b + a) - sin(sqrt(d*x + c)*b + a ))*c*f/d + a^3*f*cos(sqrt(d*x + c)*b + a)/(b^2*d) - 3*((sqrt(d*x + c)*b + a)*cos(sqrt(d*x + c)*b + a) - sin(sqrt(d*x + c)*b + a))*a^2*f/(b^2*d) + 3* (((sqrt(d*x + c)*b + a)^2 - 2)*cos(sqrt(d*x + c)*b + a) - 2*(sqrt(d*x + c) *b + a)*sin(sqrt(d*x + c)*b + a))*a*f/(b^2*d) - (((sqrt(d*x + c)*b + a)^3 - 6*sqrt(d*x + c)*b - 6*a)*cos(sqrt(d*x + c)*b + a) - 3*((sqrt(d*x + c)*b + a)^2 - 2)*sin(sqrt(d*x + c)*b + a))*f/(b^2*d))/(b^2*d)
Time = 0.32 (sec) , antiderivative size = 218, normalized size of antiderivative = 1.18 \[ \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx=-\frac {2 \, {\left (\frac {{\left (\sqrt {d x + c} b \cos \left (\sqrt {d x + c} b + a\right ) - \sin \left (\sqrt {d x + c} b + a\right )\right )} e}{b} - \frac {f {\left (\frac {{\left ({\left (\sqrt {d x + c} b + a\right )} b^{2} c - a b^{2} c - {\left (\sqrt {d x + c} b + a\right )}^{3} + 3 \, {\left (\sqrt {d x + c} b + a\right )}^{2} a - 3 \, {\left (\sqrt {d x + c} b + a\right )} a^{2} + a^{3} + 6 \, \sqrt {d x + c} b\right )} \cos \left (\sqrt {d x + c} b + a\right )}{b^{2}} - \frac {{\left (b^{2} c - 3 \, {\left (\sqrt {d x + c} b + a\right )}^{2} + 6 \, {\left (\sqrt {d x + c} b + a\right )} a - 3 \, a^{2} + 6\right )} \sin \left (\sqrt {d x + c} b + a\right )}{b^{2}}\right )}}{b d}\right )}}{b d} \]
-2*((sqrt(d*x + c)*b*cos(sqrt(d*x + c)*b + a) - sin(sqrt(d*x + c)*b + a))* e/b - f*(((sqrt(d*x + c)*b + a)*b^2*c - a*b^2*c - (sqrt(d*x + c)*b + a)^3 + 3*(sqrt(d*x + c)*b + a)^2*a - 3*(sqrt(d*x + c)*b + a)*a^2 + a^3 + 6*sqrt (d*x + c)*b)*cos(sqrt(d*x + c)*b + a)/b^2 - (b^2*c - 3*(sqrt(d*x + c)*b + a)^2 + 6*(sqrt(d*x + c)*b + a)*a - 3*a^2 + 6)*sin(sqrt(d*x + c)*b + a)/b^2 )/(b*d))/(b*d)
Timed out. \[ \int (e+f x) \sin \left (a+b \sqrt {c+d x}\right ) \, dx=\int \sin \left (a+b\,\sqrt {c+d\,x}\right )\,\left (e+f\,x\right ) \,d x \]